The present invention generally relates to testing software, and more particularly to testing software having a user interface.
The development of software has traditionally followed a development process including stating requirements, formulating the requirements into formal specifications, designing software consistent with the specifications, and coding the design. Depending upon the intended application of the software and the available resources, including time, various verification steps are performed throughout the development cycle to ensure proper operation. For example, at the design stage, various design reviews are conducted to determine whether the proposed design will achieve the specified objectives. If not, the system design is modified or the specifications are rewritten. At the coding stage, program proofs and walk-throughs are sometimes used to identify program bugs. After the system is programmed, various tests are run against the software to verify some level of system operability.
The pressure to quickly bring products to market has presented new challenges for software makers. Not only must design and coding be accomplished in less time, but verification and testing must also be accomplished more quickly. New design tools and programming languages have helped in the design and coding aspects. However, software verification tools have been slower in developing.
As we become more and more reliant on software, error-free or near error-free software becomes increasingly important. However, with less time to verify correct operation of software system, software testing may receive less emphasis even though testing has not diminished in importance.
A method and apparatus that addresses the aforementioned problems, as well as other related problems, is therefore desirable.
In accordance with various embodiments of the invention, software having a user interface is tested by automatically evolving user inputs. The method generally entails evolving a test sequence by generating random test actions. A test sequence is created by assembling a set of interface components associated with an interface window. One of the interface components is randomly selected, and a random action is generated to apply to the interface component. The test sequence is documented by recording data that identifies the interface component and the action, and the action is then applied to the user interface.
In another embodiment, a test sequence is further evolved by repeating the actions of a test sequence in a previously created log file. Some of the entries are randomly discarded, and a new log file is created that includes the entries from the old log file without the discarded entries.
In yet another embodiment, a test sequence is further evolved by repeating the actions of a test sequence in a previously created log file and randomly discarding and randomly adding new actions in creating new test sequence.
It will be appreciated that various other embodiments are set forth in the Detailed Description and claims which follow.